import request from '@/utils/request'

// 查询Carousel列表
export function uploadImg(data) {
  return request({
    url: '/file/upload',
    method: 'post',
    data: data
  })
}
// 新增Carousel
export function addCarousel(data) {
  return request({
    url: '/carousel/add',
    method: 'post',
    data: data
  })
}
//查询Carousel详细
export function getCarouselById(carouselId) {
  return request({
    url: '/carousel/getCarouselById/' + carouselId,
    method: 'get',
  })
}
//修改Carousel
export function updateCarouselById(data,carouselId) {
  return request({
    url: '/carousel/updateCarouselById/'+carouselId,
    method: 'put',
    data: data
  })
}
//删除Carousel
export function delCarouselById(carouselId) {
  return request({
    url: '/carousel/deleteCarouselById/'+carouselId,
    method: 'delete',
  })
}
